package com.wugenqiang.constant;

import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.Map;

/**
 * @Classname ParamConstant
 * @Description 定义参数常量
 * @Date 2019/1/25 11:34
 * @Created by WuGenQiang//fighting!!
 */
@Component
public class ParamConstant {

    public static Map<String, String> initConfig = new HashMap<>();

    public static String LOGIN_SESSION_KEY = "login_user";

    public static final String USER_IN_COOKIE = "S_L_ID";

    public static String AES_SALT = "0123456789abcdef";         //aes加密

    public static final int MAX_POSTS = 9999;                   //最大获取文章条数

    public static final int MAX_PAGE = 100;                     //最大页码

    public static final int MAX_TEXT_COUNT = 200000;            //文章最多可以输入的文字数

    public static final int MAX_TITLE_COUNT = 200;              //文章标题最多可以输入的文字个数

    public static final int HIT_EXCEED = 10;                    //点击次数超过多少更新到数据库

    public static Integer MAX_FILE_SIZE = 1048576;              //上传文件最大1M


    public static String UPDATE_SUCCESS="1";				//更新成功，显示1

    public static String UPDATE_FAILURE ="0";				//更新失败，显示0

    public static String INSERT_SUCCESS="1";					//新增成功，显示1

    public static String INSERT_FAILURE="0";					//新增失败，显示1

    public static String QUERY_SUCCESS="1";					//查询成功，显示1

    public static String QUERY_FAILURE ="0";				//查询失败，显示0

    public static String DELETE_SUCCESS="1";					//删除成功，显示1

    public static String DELETE_FAILURE="0";				//删除失败，显示0

}
